//
//  HCVRViewController.m
//  HappyChildren
//
//  Created by WillyZhao on 2017/3/13.
//  Copyright © 2017年 WillyZhao. All rights reserved.
//

#import "HCVRViewController.h"


#import "HCVRTableViewCell.h"
@interface HCVRViewController () <UITableViewDelegate,UIWebViewDelegate,UITableViewDataSource>{
    UITableView *tableView_;
    HCPopLoadingView *popLoading;
    NSMutableArray *images;
}

@end

@implementation HCVRViewController

- (void)viewDidLoad {
    [super viewDidLoad];
    
    self.textTitle = @"VR展示";
    

    
//    tableView_ = [[UITableView alloc] initWithFrame:CGRectMake(0, 0, centerView.frame.size.width, centerView.frame.size.height)];
//    tableView_.delegate = self;
//    tableView_.dataSource = self;
//    tableView_.backgroundColor = [UIColor whiteColor];
//    [centerView addSubview:tableView_];
//    
//    [tableView_ registerNib:[UINib nibWithNibName:@"HCVRTableViewCell" bundle:[NSBundle mainBundle]] forCellReuseIdentifier:@"vrcell"];
    popLoading = [[HCPopLoadingView alloc] initWithFrame:[UIScreen mainScreen].bounds];
    [popLoading showAnimate];
    UIWebView *web = [[UIWebView alloc] initWithFrame:CGRectMake(0, 0, self.centerView.frame.size.width, self.centerView.frame.size.height)];
    web.delegate = self;
    [web loadRequest:[NSURLRequest requestWithURL:[NSURL URLWithString:@"http://www.cdjiayibai.com/home/index/vr"]]];
    [self.centerView addSubview:web];
    
    // Do any additional setup after loading the view.
}

-(void)webViewDidFinishLoad:(UIWebView *)webView {
    [popLoading hidden];
}

//-(NSInteger)tableView:(UITableView *)tableView numberOfRowsInSection:(NSInteger)section {
//    return images.count;
//}
//
//-(UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath {
//    HCVRTableViewCell *cell = [tableView dequeueReusableCellWithIdentifier:@"vrcell" forIndexPath:indexPath];
//    cell.bgIMG.image = images[indexPath.row];
//    return cell;
//}
//
//-(CGFloat)tableView:(UITableView *)tableView heightForRowAtIndexPath:(NSIndexPath *)indexPath {
//    return centerView.frame.size.height/3.0;
//}

- (void)didReceiveMemoryWarning {
    [super didReceiveMemoryWarning];
    // Dispose of any resources that can be recreated.
}

/*
#pragma mark - Navigation

// In a storyboard-based application, you will often want to do a little preparation before navigation
- (void)prepareForSegue:(UIStoryboardSegue *)segue sender:(id)sender {
    // Get the new view controller using [segue destinationViewController].
    // Pass the selected object to the new view controller.
}
*/

@end
